package com.hangman;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

public class FinishedActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.finished_layout);

		String result = getIntent().getStringExtra("result");
		Button done = (Button) findViewById(R.id.finishButton);

		TextView finishedText = (TextView) findViewById(R.id.finishedText);
		finishedText.setText(result);

		done.setOnClickListener(new View.OnClickListener() {
			public void onClick(View v) {
				Intent intent = new Intent(getApplicationContext(),
						LanguagePicker.class);				
				startActivity(intent);
				finish();
			}
		});
	}
}
